package com.dlc.felear.xiaoensale.entity;

import android.support.annotation.NonNull;

import com.dlc.felear.xiaoensale.utils.UuidUtil;
import com.j256.ormlite.field.DatabaseField;
import com.j256.ormlite.table.DatabaseTable;

@DatabaseTable(tableName = "t_food_material")
public class FoodMaterial implements Comparable<FoodMaterial>{
    @DatabaseField(id = true)
    private int foodid;
    @DatabaseField
    private String foodName;
    @DatabaseField
    private long weight;
    @DatabaseField
    private int number;



    public long getWeight() {
        return weight;
    }

    public void setWeight(long weight) {
        this.weight = weight;
    }

    public int getNumber() {
        return number;
    }

    public void setNumber(int number) {
        this.number = number;
    }

    public FoodMaterial() {
    }
    public FoodMaterial(String foodName) {
        this.foodName=foodName;
    }

    public int getFoodid() {
        return foodid;
    }

    public void setFoodid(int foodid) {
        this.foodid = foodid;
    }

    public String getFoodName() {
        return foodName;
    }

    public void setFoodName(String foodName) {
        this.foodName = foodName;
    }

    @Override
    public int compareTo(@NonNull FoodMaterial o) {
        return this.getNumber()-o.getNumber();
    }
}
